import request from "@/utils/requset.js";

export const apis = {
  parentQuery: (params) => {
    return request({
      url: "/preventionCheckTaskConfig/list",
      method: "get",
      params,
    });
  },

  query: (params) => {
    return request({
      url: "/preventionCheckTask/listApp",
      method: "get",
      params,
    });
  },
  getAllTaskByUnitId: (params) => {
    return request({
      url: "/preventionUnit/getAllTaskByUnitId",
      method: "get",
      params,
    });
  },

  update: (data) => {
    return request({
      url: "/preventionCheckTaskConfig/update",
      method: "post",
      data: data,
    });
  },
  detail: (data) => {
    return request({
      url: "/preventionCheckTask/" + data,
      method: "get",
    });
  },
  updateTaskState: (data) => {
    return request({
      url: "/preventionCheckTask/updateTaskState",
      method: "post",
      data: data,
    });
  },
};
